﻿@model Irandeb4.Models.User

@{
    ViewBag.Title = "Edit";
}

<h2>MOdificar Usuario</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    @Html.HiddenFor(m => m.UserId)
    @Html.HiddenFor(m => m.UserName)
    @Html.HiddenFor(m => m.Email)
    @Html.HiddenFor(m => m.Password)
    @Html.HiddenFor(m => m.ConfirmPassword)
    <fieldset>
        <legend>Datos</legend>
            <fieldset>
                <legend>Informacion Cuenta</legend>
                <table>
                    <tr>
                        <td>
                            *@Html.LabelFor(m => m.UserName):
                        </td>
                        <td>
                            @*Html.EditorFor(m => m.UserName)
                            @Html.ValidationMessageFor(m => m.UserName)*@
                            @Html.DisplayTextFor(m => m.UserName)
                        </td>
                    </tr>
                    <tr>
                        <td>
                            *@Html.LabelFor(m => m.Email):
                        </td>
                        <td>
                            @*Html.EditorFor(m => m.Email)
                            @Html.ValidationMessageFor(m => m.Email)*@
                            @Html.DisplayTextFor(m => m.Email)
                        </td>
                    </tr>
                    <tr>
                        <td>
                            *@Html.LabelFor(m => m.UserRole):
                        </td>
                        <td>
                            @Html.DropDownList("UserRoleId",string.Empty)
                            @Html.ValidationMessageFor(m => m.UserRole)
                        </td>
                    </tr>
                </table>


            </fieldset>

            <br/>
            @Html.EditorFor(m => m.Employee)
            @Html.ValidationMessageFor(m => m.Employee)
            
        <div align="right">
            <br/>
            @Html.ActionLink("Volver", "Search")
            <input type="submit" value="Guardar" />
        </div>
    </fieldset>
}


